home *** CD-ROM | disk | FTP | other *** search
/ The X-Philes (2nd Revision) / The X-Philes Number 1 (1995).iso / xphiles / hp48_2 / cal_v103 < prev    next >
Internet Message Format  |  1995-03-31  |  17KB

  1. Path: seq!spell
  2. From: Kevin Jessup <bbwwbb@mixcom.COM>
  3. Subject:  v01i026:  cal_v103 - Calendar v1.03, Part01/01
  4. Newsgroups: comp.sources.hp48
  5. Followup-To: comp.sys.hp48
  6. Approved: spell@seq.uncwil.edu
  7.  
  8. Checksum: 3293230550 (verify with brik -cv)
  9. Submitted-by: Kevin Jessup <bbwwbb@mixcom.COM>
  10. Posting-number: Volume 1, Issue 26
  11. Archive-name: cal_v103/part01
  12.  
  13.  
  14. BEGIN_DOC cal_v103.doc
  15.  
  16. *****************************************************************************
  17. *         DOCUMENTATION FILE FOR HP48SX CALENDAR DRAWING FUNCTIONS          *
  18. *                              Version 1.03                                 *
  19. *                                                                           *
  20. *                    by Kevin Jessup  August 30, 1991                       *
  21. *****************************************************************************
  22.  
  23.  
  24. Version 1.03 differs from 1.02 in the following ways...
  25.  
  26.        - The calendar box is stored as a graphic object (GROB) rather
  27.          than generated by a program.  This makes the total package
  28.          500 bytes larger but execution speed is faster.
  29.  
  30.        - Days that have any alarms due are now shown with the numerals in
  31.          reverse video rather than with a BOX character after them.
  32.  
  33. The remainder of this documentation has been taken from version 1.02 with
  34. changes made as required.
  35.  
  36. If you have successfully loaded the binary CALENDAR directory file, a
  37. directory named CALENDAR should now be in your current working directory.
  38. Place 'CALENDAR' on the stack, execute the BYTES command and verify the
  39. following...
  40.  
  41.    Checksum (on level 2):      # D6D2 (hex) or # 54994 (decimal)
  42.    Byte count (on level 1):    3091
  43.  
  44.    Note:       The checksum will change if the day, month or year global
  45.                variables have been modified since you downloaded the
  46.                directory!
  47.  
  48.  
  49. Introduction
  50. ------------
  51. These routines will display a calendar graphic for a specific year and month
  52. on the 48SX display.  Functions are provided to move the calendar forward
  53. or backwards in month or year increments.  Day of week and leap-year func-
  54. tions are also provided.
  55.  
  56. The CALENDAR directory should contain the following objects in the order
  57. they appear below.  For ease of use, DO NOT re-order the directory.
  58. Objects preceeded with an asterisk (*) are described in detail later.  All
  59. other objects are subroutines used by the main functions and are NOT
  60. described.
  61.  
  62. Name       Object type     Purpose
  63. -------    -----------     --------------------------------------------------
  64. * CURR     program         Draws a calendar for the current month.
  65. * <-Y      program         Draws a calendar for the previous year, same month.
  66. * Y->      program         Draws a calendar for the next year, same month.
  67. * <-M      program         Draws a calendar for the previous month, same year.
  68. * M->      program         Draws a calendar for the next month, same year.
  69. * PCAL     program         Prints the last calendar dislayed.
  70. * CAL      program         Given specific month and year, draws the calendar.
  71. * DOW      program         Returns current day of week string to stack.
  72. * SDOW     program         Given a date, returns day of week string to stack.
  73. * RDOW     program         Given a date, returns day of week number to stack.
  74. * LPYR     program         Given a year, determines if it is a leap year.
  75. * ALMDATE? program         Given a date, determines if any alarms are due.
  76.   MOY      list            Months of the year.
  77.   DIM      list            Number of days in the months.
  78.   DOWL     list            Days of the week.
  79.   GENC     program         Main calendar graphic generating function.
  80.   FILLD    program         Adds days and alarm flags to the calendar graphic.
  81.   CPSDT    program         Compress date and time.
  82.   EXPDT    program         Expand date and time.
  83.   JFIX     program         Adjust for date mode.
  84.   day      real number
  85.   year     real number
  86.   month    real number
  87.   PPAR     list            Plot parameters.
  88.   CALGROB  grob            Graphics object of the calendar "frame".
  89.  
  90.  
  91. Detailed function descriptions
  92. ------------------------------
  93.  
  94. CURR   Draws a calendar for the current month.  A graphic display of the
  95.        month, year and appropriately positioned day numbers is generated.
  96.        Days that have an alarm associated with them will contain a box
  97.        to mark the alarm.
  98.  
  99. <-Y    Same as CURR but backs up one year.
  100.  
  101. Y->    Same as CURR but moves forward one year.
  102.  
  103. <-M    Same as CURR but backs up one month.
  104.  
  105. M->    Same as CURR but moves forward one month.
  106.  
  107. PCAL   Prints the current contents of the PICT variable.  If some other
  108.        program has not deleted PICT or modified it, the object printed
  109.        should be the last calendar you displayed.
  110.  
  111. CAL    Given a date on the stack in valid HP48SX date format (MM.DDYYYY or
  112.        DD.MMYYYY) displays the calendar for the month as in CURR.
  113.  
  114. DOW    Returns the current day of week text string to the stack.
  115.  
  116. SDOW   Given a date as in CAL, returns the day of week text string to the
  117.        stack.
  118.  
  119. RDOW   Same as SDOW but returns a real number.
  120.        Sunday = 0, Monday = 1,  ...  Saturday = 6.
  121.  
  122. LPYR   Given a year on level 1, returns 1 if it is a leap year, else 0.
  123.  
  124. ALMDATE?
  125.        Given a date as in CAL, returns 1 if alarms are due on that date,
  126.        else 0.  Always returns 0 if date input is less than the current
  127.        date (Does not detect past-due alarms!).
  128.  
  129.  
  130. Warranties and Support
  131. ----------------------
  132. None provided.  Programs are supplied AS IS.  Use at your own risk.
  133. This is freeware.  Modify it and/or enhance it as you see fit.
  134.  
  135. Kevin Jessup
  136. 9118 N. 85th St.
  137. Milwaukee, WI 53224
  138.  
  139. END_DOC
  140.  
  141.  
  142. BEGIN_ASC cal_v103.asc
  143. %%HP: T(3)A(R)F(.);
  144. "69A20FF73D71000000703414C47425F42470E1B20F88000400038000CFFFFFFF
  145. FFFFFFFFFFFFFFFFFFFFFFFF1040000000000000000000000000000000104000
  146. 0000000000000000000000000000104000000000000000000000000000000010
  147. 4000000000000000000000000000000010400000000000000000000000000000
  148. 0010400000000000000000000000000000001040000000000000000000000000
  149. 000000104CA2188E21EAE088E60EAA08B900C4E01042A618DA614A20882A04AA
  150. 088A002A401044AE18AAE14AE08AEA04EA08B9004E401048AA188AA14A208D2A
  151. 04AA088A008A401046E2188E214EE088E604AE088A006A401040000000000000
  152. 00000000000000000010CFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF104000010004
  153. 0000100040000100040000104000010004000010004000010004000010400001
  154. 0004000010004000010004000010400001000400001000400001000400001040
  155. 0001000400001000400001000400001040000100040000100040000100040000
  156. 104000010004000010004000010004000010CFFFFFFFFFFFFFFFFFFFFFFFFFFF
  157. FFFF104000010004000010004000010004000010400001000400001000400001
  158. 0004000010400001000400001000400001000400001040000100040000100040
  159. 0001000400001040000100040000100040000100040000104000010004000010
  160. 0040000100040000104000010004000010004000010004000010CFFFFFFFFFFF
  161. FFFFFFFFFFFFFFFFFFFF10400001000400001000400001000400001040000100
  162. 0400001000400001000400001040000100040000100040000100040000104000
  163. 0100040000100040000100040000104000010004000010004000010004000010
  164. 4000010004000010004000010004000010400001000400001000400001000400
  165. 0010CFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF1040000100040000100040000100
  166. 0400001040000100040000100040000100040000104000010004000010004000
  167. 0100040000104000010004000010004000010004000010400001000400001000
  168. 4000010004000010400001000400001000400001000400001040000100040000
  169. 10004000010004000010CFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF104000010004
  170. 0000100040000100040000104000010004000010004000010004000010400001
  171. 0004000010004000010004000010400001000400001000400001000400001040
  172. 0001000400001000400001000400001040000100040000100040000100040000
  173. 104000010004000010004000010004000010CFFFFFFFFFFFFFFFFFFFFFFFFFFF
  174. FFFF104000010004000010004000010004000010400001000400001000400001
  175. 0004000010400001000400001000400001000400001040000100040000100040
  176. 0001000400001040000100040000100040000100040000104000010004000010
  177. 0040000100040000104000010004000010004000010004000010CFFFFFFFFFFF
  178. FFFFFFFFFFFFFFFFFFFF1000000000000000000000000000000000006A800400
  179. 50514254047A2077920000000000000056900000000000001397792000000000
  180. 000005600000000000000230C1BA44B2A2A2BA4166E195BA4B21309700050D6F
  181. 6E64786503392000000000000000803200040975616274033920300000000001
  182. 9910120003046169730339201000000000000030F100040A464948540D9D20E1
  183. 6323CE22339201000000000000249063C1AFE22D9D203F2A20DCF1DBBF13F2A2
  184. 5BCF1B21305DF2293632B2130C600050548505444550D9D20E163278BF1D6BB1
  185. DBBF13ABB1339202000000000000010EEDA178BF1D6BB1DBBF13ABB133920400
  186. 0000000000010EEDA193632B2130E700050340535444550D9D20E16323392040
  187. 0000000000001050FA1DBBF1D6BB176BA133920200000000000001050FA1DBBF
  188. 1D6BB176BA193632B213047000806494C4C44414953580D9D20E16329C2A284E
  189. 2050D6F6E6478684E20409756162784E2040A464948584E2050340535444584E
  190. 20402544F4754B2A29C2A284E20304494D484E2050D6F6E647866C7D13CE2284
  191. E2050D6F6E64786ED2A2279E184E20409756162784E2040C4059525387E1AFE2
  192. 2D9D209C2A276BA1B21305DF220A132D6E201046634E13F2A2A9CF1B9691E4A2
  193. 0510002100000000000000EEDA1E4A2051000700000000000000076BA13F2A2A
  194. 9CF1B9691E4A20510008000000000000000EEDA1E4A205100001000000000000
  195. 0076BA1ED2A2387C1C2A207000002D6E20104676BA19C2A2DA5E1D6E20104684
  196. E2050D6F6E6478684E20409756162784E2040A464948584E205034053544453C
  197. E2284E208014C4D444144554F3AFE22599A15DF22AE8C1DBBF13CE229C2A276B
  198. A178BF1233A2D5CE1AFE22D9D208DBF14B2A2DBBF19C2A276BA1DBBF1B21305D
  199. F22DBBF1C42323FBF193632B21302C200607454E43414C460D9D20E1632C9432
  200. D9D20E1632684C184E20703414C47425F424634E1DCC0247A20E4A2051000000
  201. 0000000000000E4A20510000000000000000000B21300F2E184E2030D4F49584
  202. E2050D6F6E647866C7D1C2A20700000276BA184E204097561627B0BC176BA19C
  203. 2A2DA5E178BF18B9C18DBF1E4A20510003800000000000000DBBF190DA1E4A20
  204. 51000200000000000000050FA1E4A20510002000000000000000ED2A2387C163
  205. 4E1DBBF1E0CF1AE8C184E20806494C4C444149535743A24A5A193632B213084E
  206. 2080052554355425655493632B2130DB1004044F475C44047A20C2A20B000035
  207. 55E4C2A20B0000D4F4E4C2A20B0000455554C2A20B0000755444C2A20B000045
  208. 8455C2A20B0000642594C2A20B0000351445B213068000304494D43047A20339
  209. 2010000000000001303392010000000000008203392010000000000001303392
  210. 0100000000000003033920100000000000013033920100000000000003033920
  211. 1000000000000130339201000000000000130339201000000000000030339201
  212. 000000000000130339201000000000000030339201000000000000130B213001
  213. 10030D4F4953047A20C2A2031000A414E455142595C2A2051000645424255514
  214. 2595C2A20F0000D414253484C2A20F000014052594C4C2A20B0000D41495C2A2
  215. 0D0000A455E454C2A20D0000A455C495C2A2011000145574553545C2A2071000
  216. 3554054554D4245425C2A2031000F43445F4245425C2A2051000E4F46554D424
  217. 5425C2A205100044543454D4245425B2130021008014C4D444144554F380D9D2
  218. 0E1632FD332D9D2078BF184991B2130F1732D9D203FBF14B2A2B21305BF22D9D
  219. 203CE2278BF1AFE22D9D20829919C2A26C7D1279E1B21305BF22D9D203FBF14B
  220. 2A2B21305DF22B21305DF2293632B21309B00040C405952540D9D20E16321C43
  221. 2D6E201097E1632D6E201097803A2D4EB1F88E1D6E2010973392020000000000
  222. 00010D4EB1387E1D6E201097339202000000000000040D4EB1F88E1908E1EF53
  223. 293632B21305A000402544F47540D9D20E163284E20403544F47584E204044F4
  224. 75C4DBBF14BAC19C2A290DA193632B213025000403544F47540D9D20E16324B2
  225. A2299919C2A23F2A2C58C193632B2130930003044F47530D9D20E16322189184
  226. E20403544F47593632B213023000303414C430D9D20E163284E2050548505444
  227. 584E2040A46494854563284E20409756162797632DCC024563284E2050D6F6E6
  228. 478697632DCC024563284E203046169797632DCC0284E20607454E43414C4936
  229. 32B2130BA00040053414C440D9D20E1632634E104B0235EE18DBF193632B2130
  230. 4300020D4D820D9D20E16323CE2284E2050D6F6E647869C2A276BA178BF13392
  231. 01000000000000210D5CE1AFE22D9D208DBF19C2A24563284E20409756162797
  232. 6329C2A2B4402B21305DF224563284E2050D6F6E6478697632DCC0284E206074
  233. 54E43414C493632B2130FC00020E8D420D9D20E16323CE2284E2050D6F6E6478
  234. 69C2A290DA178BF19C2A2EBBE1AFE22D9D208DBF133920100000000000021045
  235. 63284E204097561627976329C2A283502B21305DF224563284E2050D6F6E6478
  236. 697632DCC0284E20607454E43414C493632B2130FC0002095D820D9D20E16324
  237. 563284E204097561627976329C2A2B440284E20607454E43414C493632B21302
  238. 500020E89520D9D20E16324563284E204097561627976329C2A28350284E2060
  239. 7454E43414C493632B213025000403455252540D9D20E16322189184E2030341
  240. 4C493632B21302D6D"
  241. END_ASC
  242.  
  243. BYTES: #D6D2h    3086
  244.  
  245. BEGIN_UU cal_v103.uu
  246. begin 644 cal.bin
  247. M2%!(4#0X+466*O!_TQ<````'0T%,1U)/0@<>*_"(`$``,`@`_/__________O
  248. M_________P$$`````````````````````00````````````````````!!```1
  249. M``````````````````$$`````````````````````00`````````````````H
  250. M```!!`````````````````````$$`````````````````````<0J@>@2K@Z(=
  251. M;N"J@)L`3`X!)&J!K1:D`HBB0*J`J`"B!`%$ZH&J'J0.J*Y`KH";`.0$`82J&
  252. M@:@:I`+8HD"J@*@`J`0!9"Z!Z!+D#HAN0.J`J`"F!`$$````````````````:
  253. M`````?S___________________\!!``0`$````$`!``0`$````$$`!``0```#
  254. M`0`$`!``0````00`$`!````!``0`$`!````!!``0`$````$`!``0`$````$$7
  255. M`!``0````0`$`!``0````00`$`!````!``0`$`!````!!``0`$````$`!``0<
  256. M`$````'\____________________`00`$`!````!``0`$`!````!!``0`$``$
  257. M``$`!``0`$````$$`!``0````0`$`!``0````00`$`!````!``0`$`!````!3
  258. M!``0`$````$`!``0`$````$$`!``0````0`$`!``0````00`$`!````!``0`B
  259. M$`!````!_/___________________P$$`!``0````0`$`!``0````00`$`!`4
  260. M```!``0`$`!````!!``0`$````$`!``0`$````$$`!``0````0`$`!``0```#
  261. M`00`$`!````!``0`$`!````!!``0`$````$`!``0`$````$$`!``0````0`$7
  262. M`!``0````?S___________________\!!``0`$````$`!``0`$````$$`!``$
  263. M0````0`$`!``0````00`$`!````!``0`$`!````!!``0`$````$`!``0`$``?
  264. M``$$`!``0````0`$`!``0````00`$`!````!``0`$`!````!!``0`$````$`3
  265. M!``0`$````'\____________________`00`$`!````!``0`$`!````!!``01
  266. M`$````$`!``0`$````$$`!``0````0`$`!``0````00`$`!````!``0`$`!`6
  267. M```!!``0`$````$`!``0`$````$$`!``0````0`$`!``0````00`$`!````!3
  268. M``0`$`!````!_/___________________P$$`!``0````0`$`!``0````00`?
  269. M$`!````!``0`$`!````!!``0`$````$`!``0`$````$$`!``0````0`$`!``X
  270. M0````00`$`!````!``0`$`!````!!``0`$````$`!``0`$````$$`!``0```3
  271. M`0`$`!``0````?S___________________\!``````````````````````"F)
  272. M"$``!14D14"G`G<I`````````&4)````````,7F7`@```````%`&````````X
  273. M(`,<JT0K*BJK%&8>6:NT$@-Y`%#0]N9&AU8PDP(`````````"",`0)!7%B9'K
  274. M,),"`P`````0F0$A`#!`%I8W,),"`0````````,?`$"@9)2$1=#9`AXV,NPB@
  275. M,RD0````````0@DV'/HNTMD"\Z("S1^]^S$O*K7\L1(#U2^28R,K,<`&``5%"
  276. M6%!$5`6=+>!A(X?[T;8;O?LQNALS*2`````````0X-X:A_O1MAN]^S&Z&S,IC
  277. M0````````!#@WAHY-K(2`WX`4#`$-45$5=#9`AXV,I,"!`````````$%K]&[6
  278. M'VV[<;8:,RD@````````$%#P&KW[T;8;9ZN18R,K,4`'``A&24Q,1$%94PB=T
  279. M+>!A(\FB@N0"!6UO;G1H2"Y`D%<6)H?D`@1*1DE82"Y0,`0U142%Y`($4D1/]
  280. M5[2BDBPJ2"XP0)34A.0"!6UO;G1HQM<Q[")(+E#0]N9&A^8M*G+I@>0"!'EE(
  281. M87)(+D#`!)4E-7@>^B[2V0+)HG*V&BLQ4/TBH#'2Y@(!9#;D,2\JFORQ:1E.&
  282. M*E`!`!(`````````[JWAI`(5`'``````````<+8:\Z*BR1^;EN&D`A4`@```L
  283. M``````#@WAI.*E`!`!``````````9ZOA+2J#Q\&B`@<``-+F`@%D9ZN1+"JM>
  284. MY='F`@%D2"Y0T/;F1H>&Y`($>65A<D@N0*!DE(2%Y`(%0U!31%3#+H+D`@A!Y
  285. M3$U$051%/_HN4ID:U2^BCAR]^S'L(LFB<K8:A_LA,RI=[*'O(ITM@+T?M*+2M
  286. MNQ_)HG*V&KW[L1(#U2_2NQ],,C*_'SDVLA(#P@)@<%3D-!3$9-#9`AXVPDDCG
  287. MG2W@82.&Q('D`@=#04Q'4D]"-N31S"!T*N"D`A4```````````#@I`(5````*
  288. M````````L!(#\.*!Y`(#34]92"Y0T/;F1H=F?!TL*G```"!GJX'D`@1Y96%RC
  289. M"\MQMAK)HM):'H?[@9L<V/OAI`(5`#`(````````T+L?":WAI`(5`"``````,
  290. M````4/`:3BI0`0`"`````````-ZB,G@<-N31NQ\._*&.'$@N@&"4Q,1$%)0UT
  291. M=30JI*618R,K,8#D`@A04D5315)613DVLA(#O0%`0/1TQ41`IP(L*K```%-5#
  292. M3BPJL```34].+"JP``!4544L*K```%=%1"PJL```5$A5+"JP``!&4DDL*K``!
  293. M`%-!5"LQ8`@``T1)30-T*C"3`@$``````!`#,RD0````````*#"3`@$`````3
  294. M`!`#,RD0````````,#"3`@$``````!`#,RD0````````,#"3`@$``````!`#`
  295. M,RD0````````,3"3`@$````````#,RD0````````,3"3`@$````````#,RD0,
  296. M````````,;`2`Q`!,-#TE#5`IP(L*C`!`$I!3E5!4EDL*E`!`$9%0E)505)9D
  297. M+"KP``!-05)#2"PJ\```05!224PL*K```$U!62PJT```2E5.12PJT```2E5,3
  298. M62PJ$`$`055'55-4+"IP`0!315!414U"15(L*C`!`$]#5$]"15(L*E`!`$Y/Q
  299. M5D5-0D52+"I0`0!$14-%34)%4BLQ`!(`"$%,341!5$4_")TMX&$CWS/2V0*'(
  300. M^X&4&2LQ\'$CG2TPOQ^THK(2`[4OTMD"PRYRN!_Z+M+9`BB9D2PJQM<AEQXKB
  301. M,5#[(ITM,+\?M**R$@/5+[(2`]4ODF,C*S&0"P`$3%!94@2=+>!A(\$TTN8"8
  302. M`7D>-M+F`@%Y"*/2Y!N/Z-'F`@%Y,RD@````````$-#D&X/GT>8"`7DS*2``\
  303. M``````!`T.0;C^B1@![^-9)C(RLQ4`H`!%)$3U<$G2W@82-(+D`P1?1TA>0"P
  304. M!$1/5TR]^T&K',FBDM`:.3:R$@-2`$`P1?1T1=#9`AXV0BLJDIF1+"KSHL*%2
  305. M'#DVLA(#.0`P0/1T-=#9`AXV(H$92"Y`,$7T=)5C(RLQ(`,``T-!3`.=+>!A,
  306. M(T@N4%"$!45$A>0"!$I&25A4-H+D`@1Y96%R>3;2S"!4-H+D`@5M;VYT:'DV3
  307. MTLP@5#:"Y`(#9&%Y>3;2S"!(+F!P5.0T%,248R,K,;`*``100T%,!)TMX&$C9
  308. M-N0!M"!3[H&]'SDVLA(#-``@T-0HT-D"'C8R[")(+E#0]N9&AY8L*F>K<;@?*
  309. M,RD0````````$M#%'OHNTMD"V/N1+"I4-H+D`@1Y96%R>3:2+"I+!+(2`]4O$
  310. M0F4C2"Y0T/;F1H>69R/-#(+D`@9'14Y#04PY-K(2`\\`(.#8)-#9`AXV,NPB2
  311. M2"Y0T/;F1H>6+"H)K7&X'\FBXKL>^B[2V0+8^S&3`@$``````"`!5#:"Y`($$
  312. M>65A<GDVDBPJ.`6R$@/5+T)E(T@N4-#VYD:'EF<CS0R"Y`(&1T5.0T%,.3:R&
  313. M$@//`""0U2C0V0(>-D)E(T@N0)!7%B:79R/)HK)$($@N8'!4Y#04Q)1C(RLQD
  314. M(`4``HY9`ITMX&$C5#:"Y`($>65A<GDVDBPJ.`6"Y`(&1T5.0T%,.3:R$@-2_
  315. ;`$`P5"4E1=#9`AXV(H$92"XP,!3$E&,C*S$`E
  316. ``
  317. end
  318. END_UU
  319.